﻿
@{
    ViewBag.Title = Resources.WebStringsWeb.WebTitle;
    Layout = "~/Views/Shared/_LayoutMobile.cshtml";
}
@section css {
    <style>
        .IsException {
            color: red;
        }

        .IsNormal {
            color: blue;
        }

        .mui-bar ~ .mui-content .mui-scroll-wrapper {
            top: 44px;
            height: auto;
        }
    </style>
}
<header class="mui-bar mui-bar-nav">
    <a href="../CheckForm/MCheckMenu" class="mui-icon mui-icon-left-nav mui-pull-left"></a>
    <h1 class="mui-title" style="color:white;">专项检查任务</h1>
</header>
<div class="mui-content">
    <div id="pullrefresh" class="mui-scroll-wrapper">
        <div class="mui-scroll" id="checklist">
            <ul ng-cloak class="mui-table-view mui-table-view-chevron mui-table-view-striped mui-table-view-condensed" ng-cloak ng-controller="CheckFormController" ng-init="SearchModel={};
                 TaskId='@(Request.QueryString["TaskId"].IsEmpty() ? "" : Request.QueryString["TaskId"])';
                InitMySpecialCheckTaskList();">
                <li class="mui-table-view-cell" ng-show="CheckTaskList.length==0" style="height:200px;text-align:center;font-weight:bold;background-color:rgb(239,239,244);border:none;color:gray;">暂无数据...</li>
                <li class="mui-table-view-cell" ng-repeat="x in CheckTaskList" id="{{x.FormId}}">
                    <div style="position: absolute; top: 50%; right: 15px; -webkit-transform: translateY(-50%); transform: translateY(-50%);">
                        <span class="mui-icon mui-icon-more"></span>
                    </div>
                    <div class="mui-slider-right mui-disabled">
                        <a ng-show="x.Process==2" class="mui-btn mui-btn-green" href="MSpecialCheckAdd?Id={{x.Id}}" style="transform: translate(0px, 0px);">检查</a>
                        <a class="mui-btn mui-btn-blue" href="MSpecialCheckRecordList?TaskId={{x.Id}}" style="transform: translate(0px, 0px);">台账</a>
                    </div>
                    <div class="mui-table mui-slider-handle" ng-class="{'IsException':x.IsException}">
                        <div class="mui-table-cell mui-col-xs-10" ng-class="{'IsException':x.IsNormal}">
                            <h4 class="mui-ellipsis">{{x.TaskName}}</h4>
                            <h5><b>时间：{{x.StartTime|JSONDate:'MM-dd'}} 至 {{x.EndTime|JSONDate:'MM-dd'}}</b></h5>
                            <p class="mui-h6 mui-ellipsis">备注：{{x.Remark}}</p>
                        </div>
                        <div class="mui-table-cell mui-col-xs-2 mui-text-right">
                            <span class="mui-h5">{{x.CheckTime|JSONDate:'MM-dd'}}</span>
                        </div>
                    </div>
                </li>
            </ul>
        </div>
    </div>
</div>
@section js{
    <script src="~/Assets/js/mui.pullToRefresh.js"></script>
    <script src="~/Assets/js/mui.pullToRefresh.material.js"></script>
    <script src="~/Assets/js/pg/MCheckForm.js?v=@DateTime.Now.ToString("yyyyMMddHHmm")"></script>

    <script>
        mui.init({
            swipeBack: false,
            keyEventBind: {
                backbutton: false  //关闭back按键监听
            }
        });
        //mui.showLoading("正在加载..", "div");
        //setTimeout(function () {
        //    mui.hideLoading();
        //}, 2000);


    </script>
}
